package com.appwoo.txtws.activity;

import android.app.TabActivity;
import android.content.Intent;
import android.content.res.Resources;
import android.os.Bundle;
import android.widget.RadioGroup;
import android.widget.RadioGroup.OnCheckedChangeListener;
import android.widget.TabHost;
import android.widget.TabHost.TabSpec;
import android.widget.TabWidget;

public class RecordActivity extends TabActivity
  implements RadioGroup.OnCheckedChangeListener
{
  private static final String TAB_TAG_GAME = "tab_tag_game";
  private static final String TAB_TAG_PIC = "tab_tag_pic";
  private static final String TAB_TAG_WEB = "tab_tag_web";
  private Intent Picintent;
  private Intent Softintent;
  private Intent Webintent;
  private TabHost mTabHost;
  private TabWidget mTabWidget;
  private RadioGroup mainTab;

  private TabHost.TabSpec buildTabSpec(String paramString, int paramInt1, int paramInt2, Intent paramIntent)
  {
    return this.mTabHost.newTabSpec(paramString).setIndicator(getString(paramInt1), getResources().getDrawable(paramInt2)).setContent(paramIntent);
  }

  private void prepareIntent()
  {
    Bundle localBundle1 = new Bundle();
    localBundle1.putString("RecordTypeJBCX", "0");
    localBundle1.putString("webType", "all");
    this.Webintent = new Intent(this, RecordDateActivity.class);
    this.Webintent.putExtras(localBundle1);
    Bundle localBundle2 = new Bundle();
    localBundle2.putString("RecordTypeJBCX", "1");
    localBundle2.putString("webType", "all");
    this.Softintent = new Intent(this, RecordDateActivity.class);
    this.Softintent.putExtras(localBundle2);
    Bundle localBundle3 = new Bundle();
    localBundle3.putString("RecordTypeJBCX", "2");
    localBundle3.putString("webType", "all");
    this.Picintent = new Intent(this, RecordDateActivity.class);
    this.Picintent.putExtras(localBundle3);
  }

  private void setupIntent()
  {
    this.mTabHost = getTabHost();
    TabHost localTabHost = this.mTabHost;
    localTabHost.addTab(buildTabSpec("tab_tag_web", 2131427335, 2130837728, this.Webintent));
    localTabHost.addTab(buildTabSpec("tab_tag_game", 2131427344, 2130837728, this.Softintent));
    localTabHost.addTab(buildTabSpec("tab_tag_pic", 2131427344, 2130837728, this.Picintent));
  }

  public void onCheckedChanged(RadioGroup paramRadioGroup, int paramInt)
  {
    switch (paramInt)
    {
    default:
      return;
    case 2131493370:
      this.mTabHost.setCurrentTabByTag("tab_tag_web");
      return;
    case 2131493219:
      this.mTabHost.setCurrentTabByTag("tab_tag_game");
      return;
    case 2131493221:
    }
    this.mTabHost.setCurrentTabByTag("tab_tag_pic");
  }

  public void onCreate(Bundle paramBundle)
  {
    super.onCreate(paramBundle);
    setContentView(2130903178);
    this.mainTab = ((RadioGroup)findViewById(2131493369));
    this.mainTab.setOnCheckedChangeListener(this);
    prepareIntent();
    setupIntent();
  }
}

/* Location:           C:\Documents and Settings\Administrator\classes_dex2jar.jar
 * Qualified Name:     com.appwoo.txtws.activity.RecordActivity
 * JD-Core Version:    0.6.2
 */